package com.lopo.mapper;

import com.lopo.bean.Bean;
import com.lopo.bean.TestBean;
import com.lopo.pagehelper.Pagination;
import org.apache.ibatis.annotations.*;

import java.util.Date;
import java.util.List;

@Mapper
public interface DateMapper {

    @Insert("insert into test(name,ss) values(#{name},#{ss})")
    void save(TestBean testBean);


    @Pagination
    @Select("select * from test")
    List<TestBean> selectList(@Param("pageNumber") Integer pageNumber, @Param("pageSize")Integer pageSize);

    @Select("select * from t where b =#{id}")
    List<Bean> selectBean(Long id);


    @Insert("insert into auto(name) values(#{name})")
    void save2(TestBean testBean);

    @Update("update auto set name = #{name} where id =1")
    void update(@Param("name") String name);
}
